import { Link } from "react-router-dom";
import { ICompany } from "../../types";
import style from "./style.module.css";

interface Props {
  company: ICompany;
}

export default function HomeCompanyItem(props: Props) {
  return (
    <Link
      to={"/company/detaile/" + props.company._id}
      className={style.company}
    >
      <img src={props.company.logo} alt="" className={style.logo} />
      <div className={style.Info}>
        <div className={style.companyName}>
          {props.company.companyShortName}
        </div>
        <div className={style.recruitNumber}>
          在招岗位{props.company?.recruits.length}
        </div>
      </div>
    </Link>
  );
}
